package com.neusoft.my12306.controller;


import com.neusoft.my12306.common.res.CommonResult;
import com.neusoft.my12306.service.ISysinfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author 段静迪
 * @since 2023-07-10
 */
@RestController
@RequestMapping("/sy")
@CrossOrigin
public class SysinfoController {

    @Autowired
    ISysinfoService sysinfoService;


    @GetMapping("/q/list/{rid}")
    public CommonResult loadByRid(@PathVariable  String  rid){
//        return   new CommonResult();
        return   sysinfoService.loadByRid(rid);
    }


    @GetMapping("/q/all/list")

    public CommonResult loadAllByList(){
//        return   new CommonResult();
        return   sysinfoService.loadAllByList();
    }

}
